﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using RestaurantManager.BusinessObject;
using System.Security.Cryptography;
namespace RestaurantManager
{
    class Utilities
    {
        public static User user = new User();
        public static string MahoaMD5(string text)
        {
            MD5CryptoServiceProvider _MD5Hasher = new MD5CryptoServiceProvider();
            byte[] bs = Encoding.UTF8.GetBytes(text);
            bs = _MD5Hasher.ComputeHash(bs);
            StringBuilder s = new StringBuilder();
            foreach (byte b in bs)
            {
                s.Append(b.ToString("x2"));
            }
            return s.ToString();
        }
    }
}
